<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">

<html>
<body>
<b>GridSphere Portlet API</b>
<p>
The GridSphere Portlet API is an implementation based upon the GridLab Portal
Technical Specification. The Portlet API presented has been based largely on
the IBM WebSphere Portlet API 4.1.
<p>
In particular the portlet hierarchy is as follows:
<p>
Portlet implements PortletSessionListener <br>
   ^                                      <br>
   |                                      <br>
PortletAdapter                            <br>
   ^                                      <br>
   |                                      <br>
AbstractPortlet implements ActionListener, MessageListener, WindowListener, PortletTitleListener <br>

<p>

Portlet developers would subclass the AbstractPortlet and override the hook
methods of the various Listeners for added functionality.
<p>
The following list is the order in which portlet lifecycle methods are invoked:
<ol>
    <li>
    {@link org.gridsphere.portlet.PortletAdapter#init(PortletConfig)} is invoked.
    This provides the application portlet with its initial configuration,
    {@link org.gridsphere.portlet.PortletConfig}.
    </li>
    <li>
    {@link org.gridsphere.portlet.PortletAdapter#initConcrete(PortletSettings)} is invoked.
    This provides the concrete portlet instance with its initial configuration,
    {@link org.gridsphere.portlet.PortletSettings}.
    </li>
    <li>
    {@link org.gridsphere.portlet.PortletAdapter#login(PortletRequest)} is invoked.
    Once a user has successfully logged in, the login() method is invoked for each of the
    portlets in their subscription list.
    </li>
    <li>
    {@link org.gridsphere.portlet.AbstractPortlet#service(PortletRequest, PortletResponse)} is invoked.
    This services the concrete portlet instance for a particular user request.
    This lifecycle method is invoked on concrete portlets for each and every user request.
    </li>
    Additionally the following lifecycle methods may be performed in the following order:
    <ol>An appropriate portlet action method is called:
        <ul>
        <li>
        {@link org.gridsphere.portlet.AbstractPortlet#actionPerformed(ActionEvent)}
        handles a portlet action event
        </li>
        <li>
        {@link org.gridsphere.portlet.AbstractPortlet#messageReceived(MessageEvent)}
        handles a portlet message event
        </li>
        <li>
        {@link org.gridsphere.portlet.AbstractPortlet#windowMinimized(WindowEvent)}
        handles a portlet window minimized event
        </li>
        <li>
        {@link org.gridsphere.portlet.AbstractPortlet#windowMaximized(WindowEvent)}
        handles a portlet window maximized event
        </li>
        <li>
        {@link org.gridsphere.portlet.AbstractPortlet#windowRestored(WindowEvent)}
        handles a portlet window restored event
        </li>
        </ul>
        An appropriate portlet render method is called:
        <ul>
        <li>
        {@link org.gridsphere.portlet.PortletAdapter#doView(PortletRequest, PortletResponse)}
        render the portlet <code>VIEW</code> mode.
        </li>
        <li>
        {@link org.gridsphere.portlet.PortletAdapter#doEdit(PortletRequest, PortletResponse)}
        render the portlet <code>VIEW</code> mode.
        </li>
        <li>
        {@link org.gridsphere.portlet.PortletAdapter#doHelp(PortletRequest, PortletResponse)}
        render the portlet <code>VIEW</code> mode.
        </li>
        <li>
        {@link org.gridsphere.portlet.PortletAdapter#doConfigure(PortletRequest, PortletResponse)}
        render the portlet <code>VIEW</code> mode.
        </li>
        </ul>
    </ol>
    <li>
    {@link org.gridsphere.portlet.PortletAdapter#logout(PortletSession)} is invoked.
    The logout() method is invoked for each of the portlets a user's subscription list.
    </li>
    <li>
    {@link org.gridsphere.portlet.PortletAdapter#destroyConcrete(PortletSettings)} is invoked.
    This destroys the concrete portlet instance.
    </li>
    <li>
    {@link org.gridsphere.portlet.PortletAdapter#destroy()} is invoked.
    This destroys the application portlet and takes it out of service.
    </li>
</ol>

</body>
</html>